home *** CD-ROM | disk | FTP | other *** search
Text File | 1997-06-28 | 1.1 KB | 60 lines | [TEXT/CWIE] |
- // View.h
-
- #ifndef View_h
- #define View_h
-
- #ifndef Rectangle_h
- #include "Rectangle.h"
- #endif
- #ifndef Sizeable_h
- #include "Sizeable.h"
- #endif
- #ifndef ContextUser_h
- #include "ContextUser.h"
- #endif
-
- class RegionObject;
- class TangibleView;
- class ViewMap;
-
- class View: public Sizeable,
- public ContextUser
- {
- friend class Pane;
-
- private:
- Pane *owner;
-
- protected:
- virtual void GainMapping();
- virtual void LoseMapping();
- virtual void ChangeBounds( Rectangle oldBounds );
-
- public:
- View();
- ~View();
-
- bool HasOwner() const { return owner != 0; }
- const Pane& Owner() const { Assert( owner != 0 ); return *owner; }
-
- bool Mapped() const;
- void Clip( RegionObject& ) const;
-
- void Update() const;
- void Update( const Rectangle& ) const;
- void Update( const RegionObject& ) const;
-
- void Redraw() const;
- void Redraw( const Rectangle& ) const;
- void Redraw( const RegionObject& ) const;
-
- void Invalidate() const;
- void Invalidate( const Rectangle& ) const;
- void Invalidate( const RegionObject& ) const;
-
- virtual void Draw( const ViewMap& ) const = 0;
- virtual TangibleView *Touch( PointObject );
- };
-
- #endif
-